<template>
  <Panel position="top-right" class="save-restore-controls">
    <el-button type="primary" size="small" @click="onNode">员工审批</el-button>
    <el-button type="primary" size="small" @click="onNode">门禁审批</el-button>
    <el-button type="primary" size="small" @click="onNode">考勤审批</el-button>
    <el-button type="primary" size="small" @click="onNode">访客审批</el-button>
    <el-button type="info" size="small" @click="onRestore">重置</el-button>
  </Panel>
</template>
<script setup>
import { Panel } from '@vue-flow/core'
import { ElMessageBox } from 'element-plus';

const emit = defineEmits(['restore']);

const onRestore = () => {
  ElMessageBox.confirm(`是否清空流程图?`, '提示', {
		confirmButtonText: '确认',
		cancelButtonText: '取消',
		type: 'warning',
	}).then(()=>{
    emit('restore')
  })
}
</script>

